Class NIHCL

With the introduction of static member functions and (useful) static member variables in R2.0, it is now possible to eliminate most global names. In R3.0, we've gathered many previously global functions and variables and made them static members of a new class, NIHCL, which is the base class of Object. Here's a list of the public functions:

static class NIHCL {

// ...

public: // static member functions

static unsigned char charBitMask(int i);

static unsigned short shortBitMask(int i);

static unsigned int intBitMask(int i);

static unsigned char bitCount(int i);

static unsigned char bitReverse(int i);

static void initialize(); // library initialization

static bool initialized(); // library initialized?

static void setError(int error, int sev ...);

} NIHCL_init;

Since all NIH Library classes inherit these members, their member functions can use these names without needing to specify a scope qualifier, except to resolve ambiguities. However, non-member functions and member functions of classes not derived from NIHCL can access them with the NIHCL scope qualifier; for example:

NIHCL::setError(ERROR_CODE, DEFAULT);